﻿using System.Dynamic;

namespace Jim.OA;

/// <summary>
/// 获取指定user可创建的流程数据列表
/// </summary>
[Sdk("/api/workflow/paService/getCreateWorkflowList", Description = "获取指定user可创建的流程数据列表")]
public class OAGetCreateWorkflowListInput : OAUserRequest<OAGetCreateWorkflowListOutput>,ISdkCustomDic
{
    /// <summary>
    /// 流程路径ids(workflowids)
    /// </summary>
    public string WorkFlowIds { get; set; }
    /// <summary>
    /// wfName:流程路径名称
    /// </summary>
    public string WorkFlowName { get; set; }
    /// <summary>
    /// 流程类型ids(workflowtypeIds)
    /// </summary>
    public string WorkFlowTypeIds { get; set; }
    /// <summary>
    /// 流程类型名称
    /// </summary>
    public string WorkFlowTypeName { get; set; }

    public SdkDictionary Dic()
    {
        SdkDictionary dic = new SdkDictionary();
        dynamic obj = new ExpandoObject();
        if (!string.IsNullOrEmpty(WorkFlowIds)) obj.wfids = WorkFlowIds;
        if (!string.IsNullOrEmpty(WorkFlowName)) obj.wfName = WorkFlowName;
        if (!string.IsNullOrEmpty(WorkFlowTypeIds)) obj.wfTypeIds = WorkFlowTypeIds;
        if (!string.IsNullOrEmpty(WorkFlowTypeName)) obj.wfTypeName = WorkFlowTypeName;
        dic.Add("conditions", obj);
        return dic;
    }
}

public class OAGetCreateWorkflowListOutput : SdkResponse { }